/*
 * @Author: 明月下
 * @Date: 2022-08-04 20:13:49
 * @LastEditors: 明月下
 * @LastEditTime: 2023-03-13 01:01:32
 * @FilePath: \ali-yun-slimming\vue3-vite\vite.config.ts
 * @Description:
 */
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import Components from 'unplugin-vue-components/vite';
import { VantResolver } from 'unplugin-vue-components/resolvers';



// https://vitejs.dev/config/
export default defineConfig({
  plugins: [
    vue(),
    Components({
      resolvers: [VantResolver()],
    }),
  ],
  base: '/slimming/',
  server: {
    host: '0.0.0.0',
    proxy: {
      '/express': {
          target: 'http://43.138.53.139:3000',//代理的地址
          changeOrigin: true,
          // rewrite: path => path.replace(/^\/api/, '')
      }
    }
  }
})
